﻿/* ######################################## *\
 * ### Copyright (C) 2009 AJ Ravindiran ### *
\* ######################################## */
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace AJRavindiran.Jolt.RuneScape.Models.Characters.Information
{
    /// <summary>
    /// Represents the character's appearance.
    /// </summary>
    public class Appearance
    {
        #region Fields
        private bool isNpc = false;
        private int npcId = -1;
        #endregion Fields

        #region Properties
        public int[] Look { get; set; }
        /// <summary>
        /// Gets or sets the character's colors.
        /// </summary>
        public int[] Colour { get; set; }
        /// <summary>
        /// Gets or sets the character's gender.
        /// </summary>
        public CharacterGender Gender { get; set; }
        #endregion Properties

        #region Constructors
        /// <summary>
        /// Constructs a new appearance class.
        /// </summary>
        public Appearance()
        {
            Look = new int[7];
            Colour = new int[5];

            Look[1] = 10;
            Look[2] = 18;
            Look[3] = 26;
            Look[4] = 33;
            Look[5] = 36;
            Look[6] = 42;

            for (int i = 0; i < 5; i++)
                Colour[i] = i * 3 + 2;
        }
        #endregion Constructors

        #region Methods
        /// <summary>
        /// Transforms the character to a npc.
        /// </summary>
        public void TransformToNpc()
        {
            this.isNpc = true;
        }

        /// <summary>
        /// Transforms the character to a npc.
        /// </summary>
        /// <param name="npcId"></param>
        public void TransformToNpc(int npcId)
        {
            this.isNpc = true;
            this.npcId = npcId;
        }

        /// <summary>
        /// Transforms the character back to a character.
        /// </summary>
        public void TransformToCharacter()
        {
            this.isNpc = false;
        }
        #endregion Methods
    }
}
